import 'viewerjs/dist/viewer.min.css';
import 'element-plus/theme-chalk/index.css';
import '../../../assets/style/element.css';
import '../../../assets/style/common.css';
import './style.css';

import '~common/vue/consoleProxy';

import { createApp } from 'vue';
import * as ElementPlusIconsVue from '@element-plus/icons-vue';
import { ElConfigProvider, ElForm, ElEmpty, ElImage, ElSelect, ElButton, ElCascader, ElCollapse, ElCheckbox, ElDropdown, ElIcon } from 'element-plus';

import App from './App.vue';
import LvPlayer from '~component/vue3/player/index.vue';
import LvInput from '~component/vue3-element/input/index.vue';
import LvDialog from '~component/vue3-element/dialog/index.vue';

const app = createApp(App);

app.use(ElForm);
app.use(ElIcon);
app.use(ElEmpty);
app.use(ElImage);
app.use(ElSelect);
app.use(ElButton);
app.use(ElCheckbox);
app.use(ElCollapse);
app.use(ElCascader);
app.use(ElDropdown);
app.use(ElConfigProvider);
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
    app.component(key, component);
}

app.component(LvInput.name, LvInput);
app.component(LvDialog.name, LvDialog);
app.component(LvPlayer.name, LvPlayer);

app.mount('#app');
